<!DOCTYPE html>
<html lang="en">
<head>
    <meta charset="UTF-8">
    <title>Title</title>
</head>
<body>
<script>
    // 定义了一个obj对象
    var obj = {
        name: "张三",
        age: 20,
        say() {
            console.log("说话");
        }
    }; // 字面量写法
    console.log(obj);
    obj.age = 30;
    console.log(obj.age)
    // 标准写法
    var obj1 = new Object({
        name: "张三",
        age: 20,
        say() {
            console.log("说话");
        }
    });
    console.log(obj == obj1);
</script>
</body>
</html>